package com.hns.can.master.web;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.hns.can.common.web.BaseController;
import com.hns.can.master.entity.BaseLineTrackRelEntity;
import com.hns.can.master.service.LineTrackRelService;
import com.hns.can.master.vo.LineTrackRelParamsVo;

/**
 * 线路轨迹分配Controller
 * @author:zhangzq
 * @email:
 * @version Revision 2.0.0
 */
@Controller
@RequestMapping("/lineTrackRel")
public class LineTrackRelController extends BaseController {
	
    @Autowired
    LineTrackRelService lineTrackRelService;
    
    /**
     *  获取上行线路轨迹
     * @param vo
     * @return
     * @throws Exception
     * @author:zhangzq
     * @email:
     */
    @RequestMapping("/getLineTrackRelUp")
    @ResponseBody
    public Object searchLineTrackRelUp(LineTrackRelParamsVo vo)throws Exception {
    	List<BaseLineTrackRelEntity> list = lineTrackRelService.getLineTrackRelUp(vo);
    	 return this.getReturnResult(list);
    }
    
    /**
     *  获取下行线路轨迹
     * @param vo
     * @return
     * @throws Exception
     * @author:zhangzq
     * @email:
     */
    @RequestMapping("/getLineTrackRelDown")
    @ResponseBody
    public Object searchLineTrackRelDown(LineTrackRelParamsVo vo)throws Exception {
    	 List<BaseLineTrackRelEntity> list = lineTrackRelService.getLineTrackRelDown(vo);
    	 return this.getReturnResult(list);
    }

}
